Skip to content

Fix all_green_check.yml - #143

Merged
mandar242 merged 2 commits into
ansible-collections:mainfrom
mandar242:fix-sonar-unit-cov
Jun 4, 2026
Merged

Fix all_green_check.yml#143
mandar242 merged 2 commits into
ansible-collections:mainfrom
mandar242:fix-sonar-unit-cov

Conversation

@mandar242

Copy link
Copy Markdown
Contributor
SUMMARY
ISSUE TYPE
  • Bugfix Pull Request
  • Docs Pull Request
  • Feature Pull Request
  • New Module Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION

@mandar242
mandar242 requested a review from beeankha June 2, 2026 18:12
@beeankha
beeankha force-pushed the fix-sonar-unit-cov branch from 5ec0849 to 5d13bde Compare June 2, 2026 18:35
@beeankha
beeankha requested a review from brahmanim June 2, 2026 18:38
@brahmanim

Copy link
Copy Markdown
Contributor

@mandar242 @beeankha Please see PR #142, which includes some corrections for running Unit and Sanity tests.
Maybe its worted to merge this PR before, event if coverage tests are failing there.
Please let me know what is your opnion?

@mandar242
mandar242 force-pushed the fix-sonar-unit-cov branch from 5d13bde to b119da2 Compare June 2, 2026 20:32
@sonarqubecloud

sonarqubecloud Bot commented Jun 2, 2026

Copy link
Copy Markdown

@brahmanim brahmanim left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just need to check why the SonarCloud scan job skipped

@beeankha

beeankha commented Jun 3, 2026

Copy link
Copy Markdown
Contributor

Just need to check why the SonarCloud scan job skipped

The sonarcloud job has an explicit fork guard in all_green_check.yml. Since this PR comes from mandar242/amazon.cloud (fork), not ansible-collections/amazon.cloud (upstream), the if is false and GitHub marks the job skipped even though all_green passed. On pull_request events from a fork, workflows run in the fork context and org-level secrets (including ANSIBLE_COLLECTIONS_ORG_SONAR_TOKEN_CICD_BOT) are not available (as documented here). The scan should run fully after merge to main (push event on upstream), or if a maintainer pushes the branch to ansible-collections/amazon.cloud and opens/updates the PR from there, or via a maintainer workflow that runs from a trusted branch.

@brahmanim

Copy link
Copy Markdown
Contributor

Just need to check why the SonarCloud scan job skipped

The sonarcloud job has an explicit fork guard in all_green_check.yml. Since this PR comes from mandar242/amazon.cloud (fork), not ansible-collections/amazon.cloud (upstream), the if is false and GitHub marks the job skipped even though all_green passed. On pull_request events from a fork, workflows run in the fork context and org-level secrets (including ANSIBLE_COLLECTIONS_ORG_SONAR_TOKEN_CICD_BOT) are not available (as documented here). The scan should run fully after merge to main (push event on upstream), or if a maintainer pushes the branch to ansible-collections/amazon.cloud and opens/updates the PR from there, or via a maintainer workflow that runs from a trusted branch.

Thank you @beeankha, for the clarification. Althought I understand our limitation with using secrets from a forked repository, that will allow us to merge new code with lower code coverage, counting on the fact that someone will have to fix it later.

@mandar242
mandar242 merged commit 4765d82 into ansible-collections:main Jun 4, 2026
55 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants